window.onload = function() {
	/*******搜索按钮覆盖按钮不变色*************/
	$(".search").parent().on("mousemove",function(){
		$(this).css("background","none");
	})
	// function oContent_recommend() {
	// 	var oImg = document.querySelectorAll('.content_recommend li a');
	// 	for(var i = 0; i < oImg.length; i++) {
	// 		(function(k) {
	// 			oImg[k].addEventListener('mouseover', ani);
	// 			function ani() {
	// 				this.style.transition = 'all 1s set-end';
	// 				this.style.transform = 'translateY(-10px)';
	// 				this.style.zIndex = '10';
	// 				this.style.boxShadow = '0px 0px 60px #133654';
	// 				this.style.borderRadius = '20px';
	// 				oImg[k].addEventListener('transitionend', function() {
	// 					oImg[k].addEventListener('mouseover', ani);
	// 				});
	// 				this.addEventListener('mouseout', function() {
	// 					this.style.transition = 'all .2s ease-in';
	// 					this.style.transform = '';
	// 					this.style.boxShadow = '';
	// 					this.style.borderRadius ='';
	// 					this.style.zIndex = '';
	// 				});
	// 			}
	// 		})(i)
	// 	}
	// }
	// oContent_recommend();
	
	function oCycling_wear() {
		var oImg = document.querySelectorAll('.dh>a');
		var qiuqiu=document.querySelectorAll('.qiuqiu');
		for(var i = 0; i < oImg.length; i++) {
			(function(k) {
				oImg[k].addEventListener('mouseover', ani);
				qiuqiu[k].addEventListener('mouseover', ani_qiu);
				function ani() {
					var that=this.firstElementChild;
					that.style.transition = 'all .1s linear';
					that.style.transform = 'scale(1.08)';
					// that.style.filter = 'blur(1px)';
					oImg[k].addEventListener('transitionend', function() {
						oImg[k].addEventListener('mouseover', ani);
					});
					this.addEventListener('mouseout', function() {
						that.style.transition = 'all .2s linear';
						that.style.transform = '';
						// that.style.filter = 'blur(0)';
					});
				}
				function ani_qiu() {
					var that=this.firstElementChild;
					var _s=this.lastElementChild;
					_s.style.transform="translateX(-15px)";
					_s.style.color="#EB413D";
					_s.style.transition = 'all .5s linear';
					that.style.transition = 'all .5s linear';
					that.style.transform = 'translateX(60px) scale(1.2)';
					qiuqiu[k].addEventListener('transitionend', function() {
						qiuqiu[k].addEventListener('mouseover', ani_qiu);
					});
					this.addEventListener('mouseout', function() {
						that.style.transition = 'all .5s linear';
						that.style.transform = '';
						that.style.filter = 'blur(0)';
						_s.style.transform="";
						_s.style.transition = 'all .5s linear';
						_s.style.color="#FFFFFF";
					});
				}
			})(i)
		}
	}
	oCycling_wear();
	function oContent_Arder() {
		var oImg = document.querySelectorAll('.content_Arder li img');
		var oImg_2 = document.querySelectorAll('.brand-right ul li img');
		for(var i = 0; i < oImg.length; i++) {
			(function(k) {
				oImg[k].addEventListener('mouseover', ani);
				function ani() {
					this.style.transition = 'all .2s linear';
					this.style.transform = 'scale(1.1)';
					oImg[k].addEventListener('transitionend', function() {
						oImg[k].addEventListener('mouseover', ani);
					});
					this.addEventListener('mouseout', function() {
						this.style.transition = 'all .1s linear';
						this.style.transform = 'scale(1)';
					});
				}
			})(i)
		}
		for(var j = 0; j < oImg_2.length; j++){
			(function(k){
				oImg_2[k].addEventListener('mouseover', ani2);
				function ani2() {
					this.setAttribute('style','transition:all .5s linear ;transform: scale(1.1);')
					oImg_2[k].addEventListener('transitionend', function() {
						oImg_2[k].addEventListener('mouseover', ani2);
					});
					this.addEventListener('mouseout', function() {
						this.style.transition = 'all .1s linear';
						this.style.transform = 'scale(1)';
					});
				}
			})(j)
		}
	}
	oContent_Arder();
	
	function oA_Color(){
		var oCl_Pink = document.querySelectorAll('.color_pink');
		var oCl_Green = document.querySelectorAll('.color_green');
		var oCl_blue = document.querySelectorAll('.color_blue');
		var oCl_brand_span = document.querySelector('.ct span');
		var oH = document.querySelectorAll('.list_man .color_h');
		for(var i = 0 ;i<oCl_Pink.length;i++){
			(function(k){
				oCl_Pink[k].addEventListener('mouseover',function(){
					this.setAttribute('style','background:rgba(255,255,255,.5);')
				})	
				oCl_Pink[k].addEventListener('mouseout',function(){
					this.style.background = '';
				})
			})(i)
		}
		for(var j = 0 ;j<oCl_Green.length;j++){
			(function(k){
				oCl_Green[k].addEventListener('mouseover',function(){
					this.setAttribute('style','background:rgba(255,255,255,.5);')
				})	
				oCl_Green[k].addEventListener('mouseout',function(){
					this.style.background = '';
				})
			})(j)
		}
		for(var o = 0 ;o<oCl_blue.length;o++){
			(function(k){
				oCl_blue[k].addEventListener('mouseover',function(){
					this.setAttribute('style','background:rgba(255,255,255,.5);')
				})	
				oCl_blue[k].addEventListener('mouseout',function(){
					this.style.background = '';
				})
			})(o)
		}
	
		// oCl_brand_span.addEventListener('mouseover',function(){
		// 	this.setAttribute('style','background: #000000;');
		// });
		// oCl_brand_span.addEventListener('mouseout',function(){
		// 	this.setAttribute('style','');
		// });

	}
	oA_Color();
	
	//遮罩
	function oZZ(){
		var oZz = document.querySelectorAll('.zz');
		for(var i = 0;i<oZz.length;i++){
			oZz[i].parentNode.setAttribute('style','position: relative;');
			oZz[i].setAttribute('style','position: absolute;top: 0px;left: 0px;display: inline-block;width: 100%;height: 100%;display: none;background: #000000;opacity: .5;');
		}
		for(var j = 0;j<oZz.length;j++){
			(function(k){
				oZz[k].parentNode.addEventListener('mouseover',function(){
					oZz[k].style.display='block';
					this.childNodes[3].children[0].style.color='#FFFFFF';
				})
				oZz[k].parentNode.addEventListener('mouseout',function(){
					oZz[k].style.display='none';
					this.childNodes[3].children[0].style.color='';
				})
			})(j)
		}
	}
	oZZ();
	/********首页大小图切换******/
	var large_pic=$(".Carousel a img");
//	$(".sm_picture ul li").each(function(){
//		$(this).on("mouseenter",function(){
//			var that=this;
//			large_pic.attr("src",$(that).children().children().attr("src"));
//		})
//	})
}